/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Luisa Portillo
 */
public class BinaryTree<E>
{
    private BinaryTree<E> value;
    private E object;
    
    
    public BinaryTree(){
    // post: constructor that generates an empty node    
    }

    public BinaryTree(E value){
    // post: returns a tree referencing value and two empty subtrees    
    }

    public BinaryTree(E value, BinaryTree<E> left, BinaryTree<E> right){
    // post: returns a tree referencing value and two subtrees    
    }

    public BinaryTree<E> left(){
    // post: returns reference to (possibly empty) left subtree
        return value;
    }

    public BinaryTree<E> parent(){
    // post: returns reference to parent node, or null
        return null;
    }

    public void setLeft(BinaryTree<E> newLeft){
    // post: sets left subtree to newLeft
    // re-parents newLeft if not null   
    }

    protected void setParent(BinaryTree<E> newParent){
    // post: re-parents this node to parent reference, or null    
    }

    //public Iterator<E> iterator()
    // post: returns an in-order iterator of the elements
    public boolean isLeftChild(){
    // post: returns true if this is a left child of parent
        return true;
    }

    public E value(){
    // post: returns value associated with this node
        return object;
    }

    public void setValue(E value){
    // post: sets the value associated with this node    
    }

    
}
